package cn.superchart.module.auth.api;

import lombok.Data;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.core.userdetails.UsernameNotFoundException;
import org.springframework.security.crypto.password.PasswordEncoder;

@Data
public abstract class UserDetailsServiceApi  implements UserDetailsService {

    public final PasswordEncoder passwordEncoder;
    public UserDetailsServiceApi(PasswordEncoder passwordEncoder) {
        this.passwordEncoder = passwordEncoder;
    }
    @Override
    public abstract UserDetails loadUserByUsername(String account) throws UsernameNotFoundException;

}
